<div class="container">
	<div class="col-xs-12">
		<div class="panel panel-default">
			<div class="panel-body">

				<!--交通方式-->
				<div class="col-xs-12">
					<div class="col-xs-1 text-right mt10">去程 :</div>
					<div class="col-xs-4">
						<select name="select_1" class="col-xs-4 form-control input-sm" ng-model="info.departure_mode" ng-disabled="!saveinfoflag">
							<option value="{{item.return_mode}}" ng-repeat="item in infoarr">{{item.name}}</option>
						</select>
					</div>
					<div class="col-xs-1 text-right mt10">返程 :</div>
					<div class="col-xs-4">
						<select class="col-xs-4 form-control input-sm" ng-model="info.return_mode" ng-disabled="!saveinfoflag">
							<option value="{{item.return_mode}}" ng-repeat="item in infoarr">{{item.name}}</option>
						</select>
					</div>
					<div class="col-xs-2">
						<button class="btn btn-primary" ng-click="save()" ng-show="saveinfoflag">保存</button>
						<button class="btn btn-link" ng-click="update()" ng-show="!saveinfoflag">修改</button>
					</div>
				</div>
				<br/>
				<br/>
				<br/>
				<br/>
				<div class="col-xs-12">
					&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
					<label>
						<input type="checkbox" ng-model="info.reference_info" ng-disabled="!saveinfoflag" />
						<span>参考信息（前台页面将显示 " 注：以下交通信息仅限参考" ）</span>
					</label>
				</div>
				<br/>
				<br/>
				<br/>

				<!--参考交通-->
				<div class="col-xs-12" ng-repeat="item in example.list" ng-init="outerIndex = $index">
					<div class="panel panel-default">
						<div class="panel-heading">
							交通信息{{$index+1}}
							<button type="button" class="btn btn-xs btn-info pull-right" ng-show="outerIndex" ng-click="deljtxx($index)">
								<span class="glyphicon glyphicon-remove" aria-hidden="true"></span>
							</button>
						</div>
						<div class="panel-body">

							<!--去程参考信息-->
							<div class="col-xs-2 text-right mt10">去程 : {{infoarr_2[info.departure_mode]}}</div>
							<div class="col-xs-2">
								<select class="col-xs-4 form-control input-sm" ng-model="item.reference_flight_go">
									<option value="1">有参考信息</option>
									<option value="0">无参考信息</option>
								</select>
							</div>
							<div class="col-xs-2" ng-show="item.reference_flight_go == 0">
								<input type="text" class="form-control input-sm" ng-model="item.departure_city_go" placeholder="出发地" />
							</div>
							<div class="col-sm-1 glyphicon glyphicon-arrow-right mt10" ng-show="item.reference_flight_go == 0"></div>
							<div class="col-xs-2" ng-show="item.reference_flight_go == 0">
								<input type="text" class="form-control input-sm" ng-model="item.arrival_city_go" placeholder="返程地" />
							</div>
							<br/><br/>
							<div class="col-xs-12" ng-show="item.reference_flight_go == 1">
								<div class="" ng-repeat="goinfo in item.go_route">
									<div class="btn btn-link btn-sm pull-left" ng-show="$index">
										中转<span ng-bind="$index"></span>
										<br/>
									</div>
									<table class="table table-bordered">
										<thead>
											<tr class="">
												<th class="" ng-show="info.departure_mode == 0 || info.departure_mode == 1">班次号</th>
												<th class="" ng-show="info.departure_mode == 0">飞机型号</th>
												<th class="" ng-show="info.departure_mode == 0">航空公司</th>
												<th class="">出发地</th>
												<th class="" ng-show="info.departure_mode != 3">到达地</th>
												<th class="" ng-show="info.departure_mode == 0 || info.departure_mode == 1">时间</th>
												<th class="" ng-show="info.departure_mode == 3">发车时间</th>
												<th class="" ng-show="info.departure_mode == 0 || info.departure_mode == 1">总时长</th>
												<th class="col-xs-2" ng-show="info.departure_mode == 0 || info.departure_mode == 1">舱位</th>
												<th class="" ng-show="info.departure_mode != 0 && info.departure_mode != 1">备注</th>
												<th class="">操作</th>
											</tr>
										</thead>
										<tbody>
											<tr class="">
												<td class="text-center" ng-show="info.departure_mode == 0 || info.departure_mode == 1">
													<input type="text" class="input-sm col-xs-10 form-control" ng-class="{true: 'mt10', false: ''}[(info.departure_mode == 0 || info.departure_mode == 1)]"
													 ng-model="goinfo.flt_no" />
												</td>
												<td class="text-center" ng-show="info.departure_mode == 0">
													<input type="text" class="input-sm col-xs-10 form-control" ng-class="{true: 'mt10', false: ''}[(info.departure_mode == 0 || info.departure_mode == 1)]"
													 ng-model="goinfo.aircraft_model" />
												</td>
												<td class="text-center" ng-show="info.departure_mode == 0">
													<input type="text" class="input-sm col-xs-10 form-control" ng-class="{true: 'mt10', false: ''}[(info.departure_mode == 0 || info.departure_mode == 1)]"
													 ng-model="goinfo.airline_company" />
												</td>
												<td class="text-center">
													<input type="text" class="input-sm col-xs-10 form-control " ng-class="{true: 'mt10', false: ''}[(info.departure_mode == 0 || info.departure_mode == 1)]"
													 ng-model="goinfo.departure_city" />
												</td>
												<td class="text-center" ng-show="info.departure_mode != 3">
													<input type="text" class="input-sm col-xs-10 form-control " ng-class="{true: 'mt10', false: ''}[(info.departure_mode == 0 || info.departure_mode == 1)]"
													 ng-model="goinfo.arrival_city" />
												</td>
												<td class="text-center" ng-show="info.departure_mode == 0 || info.departure_mode == 1">
													<span class="row" style="margin: 0;">
														<span class="col-xs-3" style="padding: 0;margin-top: 8px;">
															出发
														</span>
													<span class="col-xs-4" style="padding: 0">
															<input type="text" class="input-sm form-control" style="padding: 0" placeholder="时" ng-model="goinfo.departure_time_hour" maxlength="2" min="0" max="23"/>
														</span>
													<span class="col-xs-1" style="padding: 0">
															:
														</span>
													<span class="col-xs-4" style="padding: 0">
															<input type="text" class="input-sm form-control" style="padding: 0" placeholder="分" ng-model="goinfo.departure_time_minute"  maxlength="2" min="0" max="59"/>
														</span>
													</span>
													<span class="row" style="margin: 0">

														<span class="col-xs-3" style="padding: 0;margin-top: 8px;">
															到达
														</span>
													<span class="col-xs-4" style="padding: 0">
															<input type="text" class="input-sm form-control" style="padding: 0" placeholder="时" ng-model="goinfo.arrival_time_hour"  maxlength="2" min="0" max="23"/>
														</span>
													<span class="col-xs-1" style="padding: 0">
															:
														</span>
													<span class="col-xs-4" style="padding: 0">
															<input type="text" class="input-sm form-control" style="padding: 0" placeholder="分" ng-model="goinfo.arrival_time_minute"  maxlength="2" min="0" max="59"/>
														</span>
													</span>
												</td>
												<td class="text-center" ng-show="info.departure_mode == 3">
													<span class="row" style="margin: 0;">
														<span class="col-xs-3 " ng-class="{true: 'mt10', false: ''}[(info.departure_mode == 0 || info.departure_mode == 1)]"  style="padding: 0;margin-top: 8px;">
															出发
														</span>
													<span class="col-xs-4" style="padding: 0">
														<input type="text" class="input-sm form-control  " ng-class="{true: 'mt10', false: ''}[(info.departure_mode == 0 || info.departure_mode == 1)]"  style="padding: 0" placeholder="时" ng-model="goinfo.departure_time_hour" maxlength="2" min="0" max="23"/>
														</span>
													<span class="col-xs-1 " ng-class="{true: 'mt10', false: ''}[(info.departure_mode == 0 || info.departure_mode == 1)]" style="padding: 0">
														:
														</span>
													<span class="col-xs-4" style="padding: 0">
														<input type="text" class="input-sm form-control  " ng-class="{true: 'mt10', false: ''}[(info.departure_mode == 0 || info.departure_mode == 1)]"  style="padding: 0" placeholder="分" ng-model="goinfo.departure_time_minute" maxlength="2" min="0" max="59"/>
														</span>
													</span>
												</td>
												<td class="text-center" ng-show="info.departure_mode == 0 || info.departure_mode == 1">
													<input type="text" class="input-sm col-xs-10 form-control " ng-class="{true: 'mt10', false: ''}[(info.departure_mode == 0 || info.departure_mode == 1)]"
													 ng-model="goinfo.total_time" maxlength="4" placeholder="分钟" />
												</td>
												<td class="text-center" ng-show="info.departure_mode == 0 || info.departure_mode == 1">
													<select class="input-sm col-xs-10 form-control mt10" ng-model="goinfo.shipping_space" ng-show="info.departure_mode == 0">
														<option value="0">经济舱</option>
														<option value="1">商务舱</option>
														<option value="2">头等舱</option>
													</select>
													<select class="input-sm col-xs-10 form-control mt10" ng-model="goinfo.shipping_space" ng-show="info.departure_mode == 1">
														<option value="0">一等座</option>
														<option value="1">二等座</option>
														<option value="2">站票</option>
													</select>
												</td>
												<td class="text-center" ng-show="info.departure_mode != 0 && info.departure_mode != 1">
													<input type="text" class="input-sm col-xs-10 form-control " ng-class="{true: 'mt10', false: ''}[(info.departure_mode == 0 || info.departure_mode == 1)]"
													 placeholder="" ng-model="goinfo.remarks" />
												</td>
												<td class="text-center">
													<a class="btn btn-success btn-xs " ng-class="{true: 'mt10', false: ''}[(info.departure_mode == 0 || info.departure_mode == 1)]"
													 ng-click="addgoinfo($index, outerIndex)">添加中转</a>
													<a class="btn btn-warning btn-xs" ng-click="delgoinfo($index, outerIndex)" ng-show="$index">删除</a>
												</td>
											</tr>
										</tbody>
									</table>
								</div>
							</div>

							<!--返程参考信息-->
							<div class="col-xs-2 text-right mt10">返程 : <span ng-bind="infoarr_2[info.return_mode]"></span></div>
							<div class="col-xs-2">
								<select class="col-xs-4 form-control input-sm" ng-model="item.reference_flight_return">
									<option value="1">有参考信息</option>
									<option value="0">无参考信息</option>
								</select>
							</div>
							<div class="col-xs-2" ng-show="item.reference_flight_return == 0">
								<input type="text" class="form-control input-sm" ng-model="item.departure_city_return" placeholder="出发地" />
							</div>
							<div class="col-sm-1 glyphicon glyphicon-arrow-right mt10" ng-show="item.reference_flight_return == 0"></div>
							<div class="col-xs-2" ng-show="item.reference_flight_return == 0">
								<input type="text" class="form-control input-sm" ng-model="item.arrival_city_return" placeholder="返程地" />
							</div>
							<br/><br/>
							<div class="col-xs-12" ng-show="item.reference_flight_return == 1">
								<div class="" ng-repeat="returninfo in item.return_route">
									<div class="btn btn-link btn-sm pull-left" ng-show="$index">
										中转<span ng-bind="$index"></span>
										<br/>
									</div>
									<table class="table table-bordered">
										<thead ng-show="$index == 0">
											<tr class="">
												<th class="" ng-show="info.return_mode == 0 || info.return_mode == 1">班次号</th>
												<th class="" ng-show="info.return_mode == 0">飞机型号</th>
												<th class="" ng-show="info.return_mode == 0">航空公司</th>
												<th class="" ng-show="info.return_mode != 3">出发地</th>
												<th class="">到达地</th>
												<th class="" ng-show="info.return_mode == 0 || info.return_mode == 1">时间</th>
												<th class="" ng-show="info.return_mode == 3">发车时间</th>
												<th class="" ng-show="info.return_mode == 0 || info.return_mode == 1">总时长</th>
												<th class="col-xs-2" ng-show="info.return_mode == 0 || info.return_mode == 1">舱位</th>
												<th class="" ng-show="info.return_mode != 0 && info.return_mode != 1">备注</th>
												<th class="">操作</th>
											</tr>
										</thead>
										<tbody>
											<tr class="">
												<td class="text-center" ng-show="info.return_mode == 0 || info.return_mode == 1">
													<input type="text" class="input-sm col-xs-10 form-control " ng-class="{true: 'mt10', false: ''}[(info.return_mode == 0 || info.return_mode == 1)]"
													 ng-model="returninfo.flt_no" />
												</td>
												<td class="text-center" ng-show="info.return_mode == 0">
													<input type="text" class="input-sm col-xs-10 form-control " ng-class="{true: 'mt10', false: ''}[(info.return_mode == 0 || info.return_mode == 1)]"
													 ng-model="returninfo.aircraft_model" />
												</td>
												<td class="text-center" ng-show="info.return_mode == 0">
													<input type="text" class="input-sm col-xs-10 form-control " ng-class="{true: 'mt10', false: ''}[(info.return_mode == 0 || info.return_mode == 1)]"
													 ng-model="returninfo.airline_company" />
												</td>
												<td class="text-center">
													<input type="text" class="input-sm col-xs-10 form-control " ng-class="{true: 'mt10', false: ''}[(info.return_mode == 0 || info.return_mode == 1)]"
													 ng-model="returninfo.departure_city" />
												</td>
												<td class="text-center" ng-show="info.return_mode != 3">
													<input type="text" class="input-sm col-xs-10 form-control " ng-class="{true: 'mt10', false: ''}[(info.return_mode == 0 || info.return_mode == 1)]"
													 ng-model="returninfo.arrival_city" />
												</td>
												<td class="text-center" ng-show="info.return_mode == 0 || info.return_mode == 1">
													<span class="row" style="margin: 0;">
														<span class="col-xs-3" style="padding: 0;margin-top: 8px;">
															出发
														</span>
													<span class="col-xs-4" style="padding: 0">
															<input type="text" class="input-sm form-control" style="padding: 0" placeholder="时" ng-model="returninfo.departure_time_hour" maxlength="2" min="0" max="23"/>
														</span>
													<span class="col-xs-1" style="padding: 0">
															:
														</span>
													<span class="col-xs-4" style="padding: 0">
															<input type="text" class="input-sm form-control" style="padding: 0" placeholder="分" ng-model="returninfo.departure_time_minute"  maxlength="2" min="0" max="59"/>
														</span>
													</span>
													<span class="row" style="margin: 0">

														<span class="col-xs-3" style="padding: 0;margin-top: 8px;">
															到达
														</span>
													<span class="col-xs-4" style="padding: 0">
															<input type="text" class="input-sm form-control" style="padding: 0" placeholder="时" ng-model="returninfo.arrival_time_hour"  maxlength="2" min="0" max="23"/>
														</span>
													<span class="col-xs-1" style="padding: 0">
															:
														</span>
													<span class="col-xs-4" style="padding: 0">
															<input type="text" class="input-sm form-control" style="padding: 0" placeholder="分" ng-model="returninfo.arrival_time_minute"  maxlength="2" min="0" max="59"/>
														</span>
													</span>
												</td>
												<td class="text-center" ng-show="info.return_mode == 3">
													<span class="row" style="margin: 0;">
														<span class="col-xs-3" style="padding: 0;margin-top: 8px;" ng-class="{true: 'mt10', false: ''}[(info.return_mode == 0 || info.return_mode == 1)]" >
															出发
														</span>
													<span class="col-xs-4" style="padding: 0">
														<input type="text" class="input-sm form-control " ng-class="{true: 'mt10', false: ''}[(info.return_mode == 0 || info.return_mode == 1)]"  style="padding: 0" placeholder="时" ng-model="returninfo.departure_time_hour" maxlength="2" min="0" max="23"/>
														</span>
													<span class="col-xs-1" style="padding: 0" ng-class="{true: 'mt10', false: ''}[(info.return_mode == 0 || info.return_mode == 1)]">
														:
														</span>
													<span class="col-xs-4" style="padding: 0">
														<input type="text" class="input-sm form-control " ng-class="{true: 'mt10', false: ''}[(info.return_mode == 0 || info.return_mode == 1)]"  style="padding: 0" placeholder="分" ng-model="returninfo.departure_time_minute" maxlength="2" min="0" max="59"/>
														</span>
													</span>
												</td>
												<td class="text-center" ng-show="info.return_mode == 0 || info.return_mode == 1">
													<input type="text" class="input-sm col-xs-10 form-control mt10" ng-class="{true: 'mt10', false: ''}[(info.return_mode == 0 || info.return_mode == 1)]"
													 ng-model="returninfo.total_time" maxlength="4" placeholder="分钟" />
												</td>
												<td class="text-center" ng-show="info.return_mode == 0 || info.return_mode == 1">
													<select class="input-sm col-xs-10 form-control mt10" ng-model="returninfo.shipping_space" ng-show="info.return_mode == 0">
														<option value="0">经济舱</option>
														<option value="1">商务舱</option>
														<option value="2">头等舱</option>
													</select>
													<select class="input-sm col-xs-10 form-control mt10" ng-model="returninfo.shipping_space" ng-show="info.return_mode == 1">
														<option value="0">一等座</option>
														<option value="1">二等座</option>
														<option value="2">站票</option>
													</select>
												</td>
												<td class="text-center" ng-show="info.return_mode != 0 && info.return_mode != 1">
													<input type="text" ng-class="{true: 'mt10', false: ''}[(info.return_mode == 0 || info.return_mode == 1)]" class="input-sm col-xs-10 form-control"
													 placeholder="" ng-model="returninfo.remarks" />
												</td>
												<td class="text-center">
													<a class="btn btn-success btn-xs " ng-click="addreturninfo($index, outerIndex)">添加中转</a>
													<a class="btn btn-warning btn-xs" ng-click="delreturninfo($index, outerIndex)" ng-show="$index">删除</a>
												</td>
												<br/>
											</tr>
										</tbody>
									</table>
								</div>
							</div>

						</div>
					</div>
					<br/>
					<br/>
					<br/>
				</div>

				<!--添加参考信息-->
				<div class="col-xs-12">
					<a ng-click="addexample()"><span class="glyphicon glyphicon-plus"></span>添加参考信息</a>
					<button class="btn btn-info pull-right" ng-click="savegoreturn()" ng-show="example.list[0]">保存交通信息</button>
					<br/>
					<br/>
					<br/>
				</div>

				<!--短信提醒-->
				<div class="col-xs-12">
					<div class="panel panel-default">
						<div class="panel-body">
							<form action="" name="messageForm">
								<div class="col-xs-12 row">
									<div class="col-xs-3">
										自动发出团通知 :
									</div>
									<div class="col-xs-8">
										<label>是:
										<input type="radio" name="zdfcttz" ng-model="shortMessage.automatic_send" required="required"  value="1" />
									</label>&nbsp;&nbsp;&nbsp;&nbsp;
										<label>否:
										<input type="radio" name="zdfcttz"  ng-model="shortMessage.automatic_send" value="0"/>
									</label>&nbsp;&nbsp;&nbsp;&nbsp; ( 若选是通过短信形式发送 )
									</div>
								</div>
								<br/>
								<br/>
								<div class="col-xs-12 row">
									<div class="col-xs-3">
										联系人电话 :
									</div>
									<div class="col-xs-8">
										<input type="text" class="form-control" ng-model="shortMessage.tour_guide_mobile" required="required" />
									</div>
								</div>
								<br/>
								<br/>
								<div class="col-xs-12 row" ng-repeat="item in shortMessage.addressTimeArray">
									<div class="col-xs-3">
										集合地点^时间 <span ng-bind="$index + 1" ng-show="shortMessage.addressTimeArray.length - 1"></span>:
									</div>
									<div class="col-xs-5">
										<input type="text" class="form-control" ng-model="item.address" required="required" />
									</div>
									<div class="col-xs-3">
										<div class="col-xs-5">
											<input type="number" class="form-control" ng-model="item.time_hour" max="23" min="0" maxlength="2" minlength="1" placeholder="时"
											 required="required" />
										</div>
										<div class="col-xs-1 mt10">:</div>
										<div class="col-xs-5">
											<input type="number" class="form-control" ng-model="item.time_minute" max="59" min="0" maxlength="2" minlength="1" placeholder="分"
											 required="required" />
										</div>
									</div>
									<div class="col-xs-1 row">
										<div class="col-xs-2">
											<a class="btn btn-sm btn-success" ng-click="addAddressTime()" ng-show="!$index">添加</a>
										</div>
										<div class="col-xs-2">
											<a class="btn btn-sm btn-warning" ng-click="deleteAddressTime($index)" ng-show="$index">删除</a>
										</div>
									</div>
									<br/>
									<br/>
								</div>
								<br/>
								<br/>
								<div class="col-xs-12 row">
									<div class="col-xs-3">
										是否提供接机(站)服务 :
									</div>
									<div class="col-xs-8">
										<label>是:
										<input type="radio" name="pick_up_service" ng-model="shortMessage.pick_up_service" value="1" required="required"/>
									</label>&nbsp;&nbsp;&nbsp;&nbsp;
										<label>否:
										<input type="radio" name="pick_up_service" ng-model="shortMessage.pick_up_service" value="0"/>
									</label>&nbsp;&nbsp;&nbsp;&nbsp; ( 若选是通过短信形式发送 )
									</div>
								</div>
								<br/>
								<br/>
								<div class="col-xs-12 row" ng-show="shortMessage.pick_up_service == 1">
									<div class="col-xs-3">
										备注 :
									</div>
									<div class="col-xs-8">
										<textarea cols="50" rows="5" ng-model="shortMessage.remarks"></textarea>
									</div>
								</div>

							</form>
						</div>
					</div>
				</div>

				<!--添加参考信息-->
				<div class="col-xs-12">
					<div class="pull-right">&nbsp;&nbsp;&nbsp;&nbsp;</div>
					<button class="btn btn-info pull-right" ng-click="savemessAge()">保存短信</button>
				</div>
			</div>
		</div>
	</div>
</div>